<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8"/>
    <title>资讯列表</title>
    <meta name="renderer" content="webkit"/>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
    <meta name="apple-mobile-web-app-status-bar-style" content="black"/>
    <meta name="apple-mobile-web-app-capable" content="yes"/>
    <meta name="format-detection" content="telephone=no"/>
    <link rel="stylesheet" href="../../layui/css/layui_v2.1.5.css" media="all"/>
    <link rel="stylesheet" href="../../layui/css/layui.css" media="all" />
    <link rel="stylesheet" href="//at.alicdn.com/t/font_tnyc012u2rlwstt9.css" media="all" />
    <link rel="stylesheet" href="../../css/style.css" media="all" />

    <style type="text/css">
        .label_1{
            background: #35C6D1;
            height: 22px;
            line-height: 22px;
            padding: 0 8px;
            font-size: 12px;
            color: #fff;
            border-radius: 3px;
            position: relative;
        }

        .close{
            position: absolute;
            top: -4px;
            right: -4px;
            color: #a6a6a6;
            box-shadow: 0 0 5px #000000;
            display: inline-block;
            width: 10px;
            height: 10px;
            line-height: 10px;
            border-radius: 5px;
            cursor: pointer;
            font-size: 14px;
        }

    </style>
</head>

<body class="childrenBody">
<blockquote class="layui-elem-quote information_search">
    <form class="layui-form">
        <div class="layui-form-item" style="margin-bottom: 0px;">
            <div class="layui-inline">
                <label class="layui-form-label">标题</label>
                <div class="layui-input-inline">
                    <input type="text" value="" placeholder="请输入标题..." class="layui-input search_input" id="search_input"/>
                </div>
            </div>

            <div class="layui-inline">
                <label class="layui-form-label">栏目</label>
                <div class="layui-input-inline">
                    <select name="navType" id="navType">
                        <option value=""></option>
                        <option th:each="nav,iterStat:${navList}" th:value="${iterStat.index}" th:text="${nav}"></option>
                    </select>
                </div>
            </div>

            <div class="layui-inline">
                <label class="layui-form-label">起始时间</label>
                <div class="layui-input-inline">
                    <input type="text" placeholder="起始时间..." class="layui-input linksTime" lay-verify="date" onclick="layui.laydate({elem:this})" id="startTime"/>
                </div>
            </div>

            <div class="layui-inline">
                <label class="layui-form-label">结束时间</label>
                <div class="layui-input-inline">
                    <input type="text" placeholder="结束时间..." class="layui-input linksTime" lay-verify="date" onclick="layui.laydate({elem:this})" id="endTime"/>
                </div>
                <a class="layui-btn search_btn" id="searchBtn">查询</a>
            </div>
        </div>
    </form>
</blockquote>
<div class="layui-form" id="informations_list">

    <style>
        .nav-type{
            background: #ff00f7;
            padding:2px 5px;
            color: #fff;
            font-size:12px;
            border-radius: 3px;
        }
    </style>

    <div type="text/css" th:replace="fragment/fragment::infoStyle"></div>


    <!--<table class="layui-table">-->
        <!--<colgroup>-->
            <!--&lt;!&ndash;<col width="10%"/>&ndash;&gt;-->
            <!--&lt;!&ndash;<col width="18%"/>&ndash;&gt;-->
            <!--&lt;!&ndash;<col width="18%"/>&ndash;&gt;-->
            <!--&lt;!&ndash;<col width="18%"/>&ndash;&gt;-->
            <!--&lt;!&ndash;<col width="18%"/>&ndash;&gt;-->
            <!--&lt;!&ndash;<col width="18%"/>&ndash;&gt;-->
        <!--</colgroup>-->
        <!--<thead>-->
        <!--<tr>-->
            <!--<th><input type="checkbox" name="" lay-skin="primary" lay-filter="allChoose" id="allChoose"/></th>-->
            <!--<th>标题</th>-->
            <!--<th>来源</th>-->
            <!--<th>作者</th>-->
            <!--<th>封面图</th>-->
            <!--<th>状态</th>-->
            <!--<th>推荐</th>-->
            <!--<th>推送</th>-->
            <!--<th>显示</th>-->
            <!--<th>操作</th>-->
        <!--</tr>-->
        <!--</thead>-->
        <!--<tbody id="informationListTb">-->

        <!--</tbody>-->
    <!--</table>-->

    <div class="layui-fluid info-list" id="informationListTb">

    </div>


</div>
<div id="pagination">
    <!--<input type="hidden" th:value="${informationDataMap.total}" id="pageTotal"/> &lt;!&ndash; 总条数 &ndash;&gt;-->
    <!--<input type="hidden" th:value="${informationDataMap.page+1}" id="pageNum"/>　　&lt;!&ndash; 第几页 &ndash;&gt;-->
</div>


<!--<script type="text/html" id="informationList">-->
    <!--{{if list != null}}-->
    <!--{{each list as value i}}-->
    <!--<tr>-->
        <!--<td><input type="checkbox" name="checked" lay-skin="primary" lay-filter="choose"/></td>-->
        <!--<td style="text-align:left;" informationId="{{value.id}}">{{value.title}}</td>-->
        <!--{{if value.fromType == "0"}}-->
        <!--<td>原创</td>-->
        <!--{{else}}-->
        <!--<td>转载</td>-->
        <!--{{/if}}-->
        <!--<td>{{value.author}}</td>-->
        <!--<td><img src="{{value.coverUrl | subString}}" alt="123"/></td>-->
        <!--<td infoStatus="{{value.status}}">{{value.statusValue}}</td>-->
        <!--<td><input type="checkbox" name="show" lay-skin="switch" lay-text="是|否" lay-filter="isShow" checked="checked"/></td>-->
        <!--<td><input type="checkbox" name="show" lay-skin="switch" lay-text="是|否" lay-filter="isShow" checked="checked"/></td>-->
        <!--<td><input type="checkbox" name="show" lay-skin="switch" lay-text="是|否" lay-filter="isShow" checked="checked"/></td>-->
        <!--<td>-->
            <!--<a class="layui-btn layui-btn-mini news_edit"><i class="iconfont icon-edit"></i> 撤回重审</a>-->
            <!--&lt;!&ndash;<a class="layui-btn layui-btn-normal layui-btn-mini news_collect"><i class="layui-icon">&#xe600;</i> 收藏</a>&ndash;&gt;-->
            <!--<a class="layui-btn layui-btn-danger layui-btn-mini news_del" data-id="'+data[i].newsId+'"><i class="layui-icon">&#xe640;</i> 下架</a>-->
        <!--</td>-->
    <!--</tr>-->
    <!--{{/each}}-->
    <!--{{else}}-->
    <!--<tr style="text-align: center;"><td colspan="7">暂无数据</td></tr>-->
    <!--{{/if}}-->
<!--</script>-->

<script type="text/html" id="informationList">
    {{if list != null}}
    {{each list as value i}}
        <div class="layui-row">
            <div class="layui-col-xs12 layui-col-sm12 layui-col-md12">
                <div class="layui-row">
                    <div class="layui-col-xs12 layui-col-sm6 layui-col-md6 cover-img">
                        <img src="{{value.coverUrl | subString}}" alt="cover"/>
                    </div>
                    <div class="layui-col-xs12 layui-col-sm6 layui-col-md6">
                        <div class="info">
                            <p>
                                <span class="layui-show-md-inline-block title" infoId="{{value.id}}" title="点击查看详情">
                                {{value.title}}
                                </span>
                            </p>
                            <p th:include="fragment/fragment::navFragment"></p>
                            <p>
                                状态：
                                {{if value.status == 0}}
                                <span class="layui-show-md-inline-block status label_1">草稿</span>
                                {{else if value.status == 1}}
                                <span class="layui-show-md-inline-block status label_1">待审核</span>
                                {{else if value.status == 2}}
                                <span class="layui-show-md-inline-block status label_1">审核通过</span>
                                {{else if value.status == 3}}
                                <span class="layui-show-md-inline-block status label_1">已发布</span>
                                {{else}}
                                <span class="layui-show-md-inline-block status label_1">审核未通过</span>
                                {{/if}}
                            </p>
                            <p>
                                <span class="layui-show-md-inline-block">作者：{{value.author}}</span>
                                <!--<button class="layui-btn layui-btn-primary layui-btn-small">推荐</button>-->
                                <!--<button class="layui-btn layui-btn-small">推送</button>-->
                                <!--<button class="layui-btn layui-btn-normal layui-btn-small">用户授权</button>-->
                            </p>
                            <p>
                                <span class="layui-show-md-inline-block">创建时间：{{value.createTime}}</span>
                            </p>
                            {{if value.status == 0}}
                            <p>
                                <button class="layui-btn layui-btn-normal layui-btn-small editBtn" infoId="{{value.id}}">编辑</button>
                                <button class="layui-btn layui-btn-danger layui-btn-small delBtn" infoId="{{value.id}}">删除</button>
                            </p>
                            {{/if}}
                            <!--<p>-->
                                <!--<button class="layui-btn layui-btn-primary layui-btn-small" id="introBtn">推荐</button>-->
                                <!--<button class="layui-btn layui-btn-small" id="sendBtn">推送</button>-->
                                <!--&lt;!&ndash;<button class="layui-btn layui-btn-normal layui-btn-small" id="autho">用户授权</button>&ndash;&gt;-->
                                <!--<button class="layui-btn layui-btn-warm layui-btn-small" id="revokeBtn">撤回重审</button>-->
                                <!--<button class="layui-btn layui-btn-danger layui-btn-small" id="underBtn">资讯下架</button>-->
                                <!--&lt;!&ndash;<button class="layui-btn layui-btn-danger layui-btn-small">备用</button>&ndash;&gt;-->
                            <!--</p>-->
                        </div>
                    </div>
                </div>
            </div>
            <!--<div class="layui-col-md4">-->

            <!--</div>-->
    </div>
    {{/each}}
    {{else}}
    <div class="layui-row">
        <div class="layui-col-xs12 layui-col-sm12 layui-col-md12">暂无数据!</div>
    </div>
    {{/if}}
</script>



<script type="text/javascript" src="../../layui/layui.js"></script>
<script type="text/javascript" src="../../js/information/informationList.js?version=1.0.1"></script>
<script type="text/javascript" src="../../js/common/template.js"></script>



<script type="text/javascript">
    // 注册方法
    template.helper("subString",function (str){
        if(str==null||str==""||str==undefined){
            return "";
        }
        var _str = str.split("@@@@");
        return _str[0];
    });

</script>

</body>
</html>